package com.ss.SmartStock.controller;

import com.ss.SmartStock.pojo.entity.Supplier;
import com.ss.SmartStock.service.SupplierService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author TsingFeng
 * @date 2024/6/17 9:48
 */
@RestController
@Api(tags = "分类相关接口")
@Slf4j
public class MyController {

    @Autowired
    private SupplierService supplierService;


    @RequestMapping("/supplier/selectAllsuppliers")
    public Supplier selectAllsuppliers(){
        Supplier supplier=supplierService.getById(1);
        return  supplier;
    }

    @ApiOperation("新增分类")
    @GetMapping("/test")
    public String test(){

        return "hello";
    }


}
